# Maintainer: Jan Alexander Steffens (heftig) <heftig@archlinux.org>
# Contributor: Balló György <ballogyor+arch at gmail dot com>

pkgname=rygel
pkgver=0.42.4
pkgrel=1
epoch=1
pkgdesc="UPnP AV MediaServer and MediaRenderer"
url="https://wiki.gnome.org/Projects/Rygel"
arch=(loong64 x86_64)
license=(LGPL)
depends=(
  gst-editing-services
  gtk3
  gupnp
  gupnp-av
  gupnp-dlna
  libgee
  libmediaart
  libsoup3
  libunistring
  tracker3
)
makedepends=(
  git
  gobject-introspection
  meson
  vala
)
optdepends=(
  'gst-libav: Extra media codecs'
  'gst-plugins-bad: Extra media codecs'
  'gst-plugins-base: Extra media codecs'
  'gst-plugins-good: Extra media codecs'
  'gst-plugins-ugly: Extra media codecs'
  'tracker3-miners: Share indexed media files'
  'tumbler: Thumbnailing service'
)
provides=(librygel-{core,db,renderer,renderer-gst,ruih,server}-2.8.so)
backup=(etc/rygel.conf)
groups=(gnome)
_commit=01154a2ff6e652b281f38c615586bd2188c76f74  # tags/rygel-0.42.4^0
source=("git+https://gitlab.gnome.org/GNOME/rygel.git#commit=$_commit")
b2sums=('SKIP')

pkgver() {
  cd rygel
  git describe --tags | sed 's/^rygel-//;s/[^-]*-g/r&/;s/-/+/g'
}

prepare() {
  cd rygel
}

build() {
  arch-meson rygel build
  meson compile -C build
}

check() {
  meson test -C build --print-errorlogs
}

package() {
  meson install -C build --destdir "$pkgdir"
}

# vim:set sw=2 sts=-1 et:
